<template>
	<swiper class="banner" :indicator-dots="false" circular :autoplay="false">
		<swiper-item v-for="item in pictures" :key="item.id">
			<img @tap="onPreviewImage(item.url)" :src="item.url"  ></img>
		</swiper-item>
		
	</swiper>
</template>

<script>
	export default {
		data() {
			return {
				title: 'Hello,你好',
				 pictures:[
				          { id: '1',url: "https://pic3.zhimg.com/v2-379be37e0b4d372aa60046f9ce771f12_b.jpg"},
				          { id: '2',url: "https://c-ssl.dtstatic.com/uploads/blog/202207/18/20220718062950_f4737.thumb.400_0.jpg"},
				          { id: '3',url: "https://tse2-mm.cn.bing.net/th/id/OIP-C.Ifb9ziubQZgVNqsZNRMz5QHaEP?w=304&h=180&c=7&r=0&o=7&dpr=1.3&pid=1.7&rm=3"},
				        ]
			}
		},
		onLoad() {

		},
		methods: {
		onPreviewImage(url){
		console.log(url)
		uni.previewImage(
		{
			urls:this.pictures.map(v=>v.url),
			current:url
		})
		}
		}
	}
</script>

<style>
	.banner,
	.banner image{
	width: 750rpx;
	height: 750rpx;	
	}
</style>
